package com.ruoyi.leave.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 请假记录对象 leave_record
 * 
 * @author Weiney
 * @date 2025-03-11
 */
public class LeaveRecord extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 请假记录ID */
    private Long leaveId;

    /** 课程ID */
    @Excel(name = "课程ID")
    private Long courseId;

    /** 课程名称 */
    @Excel(name = "课程名称")
    private String courseName;

    /** 用户ID */
    private Long userId;

    /** 用户名 */
    @Excel(name = "学号")
    private String userName;

    /** 用户姓名 */
    @Excel(name = "姓名")
    private String nickName;

    /** 部门ID */
    private Long deptId;

    /** 部门名称 */
    @Excel(name = "班级")
    private String deptName;

    /** 请假原因 */
    @Excel(name = "请假原因")
    private String leaveReason;

    /** 开始时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "请假开始时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date startTime;

    /** 结束时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "请假结束时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date endTime;

    /** 审批人ID */
    private Long approvalId;

    /** 审批人姓名 */
    @Excel(name = "审批人姓名")
    private String approvalName;

    /** 审批状态：审批中、已完成 */
    @Excel(name = "审批状态", readConverterExp = "0=审批中,1=已完成")
    private Long approvalStatus;

    /** 审批结果：同意、拒绝 */
    @Excel(name = "审批结果", readConverterExp = "0=同意,1=拒绝")
    private Long approvalResult;

    /** 审批时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "审批时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date approvalTime;

    /** 批语 */
    @Excel(name = "批语")
    private String approvalComment;

    public void setLeaveId(Long leaveId) 
    {
        this.leaveId = leaveId;
    }

    public Long getLeaveId() 
    {
        return leaveId;
    }
    public void setCourseId(Long courseId) 
    {
        this.courseId = courseId;
    }

    public Long getCourseId() 
    {
        return courseId;
    }
    public void setCourseName(String courseName) 
    {
        this.courseName = courseName;
    }

    public String getCourseName() 
    {
        return courseName;
    }
    public void setUserId(Long userId) 
    {
        this.userId = userId;
    }

    public Long getUserId() 
    {
        return userId;
    }
    public void setUserName(String userName) 
    {
        this.userName = userName;
    }

    public String getUserName() 
    {
        return userName;
    }
    public void setNickName(String nickName) 
    {
        this.nickName = nickName;
    }

    public String getNickName() 
    {
        return nickName;
    }
    public void setDeptId(Long deptId) 
    {
        this.deptId = deptId;
    }

    public Long getDeptId() 
    {
        return deptId;
    }
    public void setDeptName(String deptName) 
    {
        this.deptName = deptName;
    }

    public String getDeptName() 
    {
        return deptName;
    }
    public void setLeaveReason(String leaveReason) 
    {
        this.leaveReason = leaveReason;
    }

    public String getLeaveReason() 
    {
        return leaveReason;
    }
    public void setStartTime(Date startTime) 
    {
        this.startTime = startTime;
    }

    public Date getStartTime() 
    {
        return startTime;
    }
    public void setEndTime(Date endTime) 
    {
        this.endTime = endTime;
    }

    public Date getEndTime() 
    {
        return endTime;
    }
    public void setApprovalId(Long approvalId) 
    {
        this.approvalId = approvalId;
    }

    public Long getApprovalId() 
    {
        return approvalId;
    }
    public void setApprovalName(String approvalName) 
    {
        this.approvalName = approvalName;
    }

    public String getApprovalName() 
    {
        return approvalName;
    }
    public void setApprovalStatus(Long approvalStatus) 
    {
        this.approvalStatus = approvalStatus;
    }

    public Long getApprovalStatus() 
    {
        return approvalStatus;
    }
    public void setApprovalResult(Long approvalResult) 
    {
        this.approvalResult = approvalResult;
    }

    public Long getApprovalResult() 
    {
        return approvalResult;
    }
    public void setApprovalTime(Date approvalTime) 
    {
        this.approvalTime = approvalTime;
    }

    public Date getApprovalTime() 
    {
        return approvalTime;
    }
    public void setApprovalComment(String approvalComment) 
    {
        this.approvalComment = approvalComment;
    }

    public String getApprovalComment() 
    {
        return approvalComment;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("leaveId", getLeaveId())
            .append("courseId", getCourseId())
            .append("courseName", getCourseName())
            .append("userId", getUserId())
            .append("userName", getUserName())
            .append("nickName", getNickName())
            .append("deptId", getDeptId())
            .append("deptName", getDeptName())
            .append("leaveReason", getLeaveReason())
            .append("startTime", getStartTime())
            .append("endTime", getEndTime())
            .append("createTime", getCreateTime())
            .append("approvalId", getApprovalId())
            .append("approvalName", getApprovalName())
            .append("approvalStatus", getApprovalStatus())
            .append("approvalResult", getApprovalResult())
            .append("approvalTime", getApprovalTime())
            .append("approvalComment", getApprovalComment())
            .toString();
    }
}
